import  request from '@/utils/request'

//获取计费规则
export function getFeeRuleList(params) {
  return request({
    url: '/parking/rule/list',
    method: 'get',
    params
  })
}

export function addFeeRule(data) {
  return request({
    url: 'parking/rule',
    method: 'post',
    data
  }) 
}

export function getFeeRule(id) {
  return request({
    url: `parking/rule/${id}`,
    method: 'get'
  })
}

export function updateFeeRule(data) {
  return request({
    url: '/parking/rule',
    method: 'put',
    data
  })
}

export function deleteFeeRule(id) {
  return request({
    url: `/parking/rule/${id}`,
    method: 'delete'
  }) 
}